##PBAR_Zspec_ExamineSimulatedSpectra.py

# display dataset name, counts, sigma, mean and sigma/mean for each group

groupNamesList = ('CC', 'Pb', 'Al', 'Pb3Fe', 'Pb3Al', 'Pb4Fe', 'Pb4Al')
groupNamesList = ('CC', 'Pb', 'Al', 'Fe')

groupNamesList = ('CC', 'Pb')

##statsNamesList = statsMC.keys()

statsNamesList = ('multibin_20_ratio_g', 'multibin_0_20_g', 'multibin_20_256_g', 'binMean_q50_g', 'binMean_g', 'transmission')

for groupName in groupNamesList:
    for ii in range(len(datasetGroupsIndices[groupName])):
        jj = datasetGroupsIndices[groupName][ii]
        print groupName, datasetDescription[jj], str(statsMC['transmission'][jj,:].mean())
        for key in statsNamesList:
##            print datasetGroups[groupName][ii], key, \
##                  str(statsMC[key][jj,:].std()), str(statsMC[key][jj,:].mean()), \
##                  str(statsMC[key][jj,:].std()/statsMC[key][jj,:].mean())
            print datasetGroups[groupName][ii], key + ': ', \
                  ('%3.4f' % (statsMC[key][jj,:].std()/statsMC[key][jj,:].mean()))
        print('')

# plot fluctuation as a function of thickenss of lead
